<template>
    <div class="login-form">
        <div class="g-form">
            <div class="g-form-line" v-for="formLine in formData">
                <span class="g-form-label">{{ formLine.label }}:</span>
                <div class="g-form-input">
                    <input type="text" v-model="formLine.model" :placeholder="'请输入'+formLine.label"> 
                </div>
            </div>
            <div class="g-form-line">
                <div class="g-form-btn">
                    <a class="button" @click="onLogin">注册</a>
                </div>
            </div>
        </div>
    </div>
</template>
<script>
    export default {
        props: {
            isShow : {
                type:Boolean,
                default: false
            }
        },
        data () {
            return {
                formData: [
                    {
                        label: '用户名',
                        model: username
                    },
                    {
                        label: '密码',
                        model: password
                    }
                ]
            }
        },
        computed: {
            
        },
        methods: {
            onLogin () {
                alert('恭喜你注册成功！');
            }
        }
    }
</script>
<style>

</style>
